//
//  RegisterShakeListener.m
//  Staff
//
//  Created by caiyao on 1/13/15.
//
//

#import "RegisterShakeListener.h"
#import <Cordova/UIDevice+Extensions.h>
#import <AudioToolbox/AudioToolbox.h>

@implementation RegisterShakeListener

- (void)excute {
    
    NSString *statusCode = soft_token_success_status_code_0000;
    
    if (self.command.eventJS == nil || self.command.callbackJS == nil)
    {
        // url param is missing fail to handle
        [self excuteNonHookFoundCallback];
        return;
    }
    
    
    //
    
    if ([UIDevice isPad])
    {
        //[self initShake];
    }
    else
    {
        [self.hookViewController registerShake:self.command.eventJS];
    }
    [self excuteCallBackJSWithParameters:statusCode];
}




@end
